<template>
	<view>
		<view class="detail" v-for="(item,index) in sceneDetail" :key="index">
			<view class="detail-title">
				<text>{{item.title}}</text>
			</view>
			<view class="detail-introduce">
				<text v-if="item.introduce">{{item.introduce}}</text>
			</view>
			<image :src="item.image" mode="widthFix"></image>
		</view>
	</view>
</template>

<script>
	import {
		getSceneDetail
	} from "@/common/request.js"
	
	export default {
		data() {
			return {
				sceneDetail: [],
				currentIndex: ''
			};
		},
		onLoad(options) {
			this.currentIndex = options.id
			this.getSceneDetailMsg()
		},
		methods: {
			getSceneDetailMsg() {
				getSceneDetail(this.currentIndex).then(res=>{
					this.sceneDetail=res
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.detail{
		margin: 20rpx 20rpx;
		.detail-title{
			margin-bottom: 10rpx;
			text-align: center;
		}
		.detail-introduce{
			text-align: center;
		}
	}
</style>
